package com.example.moments.repository;

import android.content.Context;
import android.util.Log;

import androidx.lifecycle.LiveData;

import com.example.moments.dao.BaseDao;
import com.example.moments.dao.ContentDao;
import com.example.moments.db.AppDatabase;
import com.example.moments.ssmemo.entity.Content;

import java.util.List;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.SynchronousQueue;
import java.util.concurrent.ThreadPoolExecutor;
import java.util.concurrent.TimeUnit;

//import en.edu.zucc.pb.loginapplication.AppDatabase;
//import en.edu.zucc.pb.loginapplication.dao.UserDao;
//import en.edu.zucc.pb.loginapplication.entity.User;

//import androidx.lifecycle.LiveData;
//import cn.chenjianlink.android.alarmclock.db.AlarmClockDao;
//import cn.chenjianlink.android.alarmclock.db.BaseAlarmClockDatabase;
//import cn.chenjianlink.android.alarmclock.model.AlarmClock;
//import cn.chenjianlink.android.alarmclock.utils.LogUtil;

/**
 * @author chenjian
 * 对数据库操作进行封装，向ViewModel提供封装方法
 */
public class ContentRepository extends BaseRepository<Content> {

//    private static ContentDao contentDao;

    public static void main(String[] args) {
//        AppDatabase database = AppDatabase.getDatabase(getApplicationContext());
//        ContentDao contentDao = database.contentDao();
//        ContentRepository contentRepository=new ContentRepository(contentDao);
//        contentRepository.update(new Content());
    }
//    private final ContentDao contentDao;

//    private final LiveData<List<User>> userList;

    /**
     * 线程池，在子线程中处理增删改
     */
//    private final ExecutorService executor;

    public ContentRepository(BaseDao<Content> baseDao) {
        super(baseDao);
    }


}
